package com.kin207.netty.udp;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.kin207.netty.session.Session;
import com.kin207.netty.session.SessionManager;

import io.netty.channel.ChannelHandlerContext;

public class UdpSessionManager extends SessionManager {
	final static Logger logger = LoggerFactory.getLogger(UdpSessionManager.class);
 
	public int sendMessage(ChannelHandlerContext ctx, String msg){
		logger.debug("send message, address:{}, message:{}", ctx.channel().remoteAddress(), msg);
		Session session = getSession(ctx);
		ctx.writeAndFlush(msg);
		return 0;
	}
}
